<?php

/**
 * comments actions.
 *
 * @package    NewsPortal
 * @subpackage comments
 * @author     Your name here
 * @version    SVN: $Id: actions.class.php 23810 2009-11-12 11:07:44Z Kris.Wallsmith $
 */
class commentsComponents extends sfComponents
{
 /**
  * Executes index action
  *
  * @param sfRequest $request A request object
  */
  public function executeList()
  {
    $this->commentss = Doctrine_Core::getTable('Comments')
    ->selectCommentsByNewsId($this->news_id);
  }
    public function executeForm()
  {
    $commentss=new Comments();        
    $commentss->setNewsId($this->news_id);
    $this->form= new CommentsForm($commentss);
  }

}
